<?php
namespace app\api\model;


use app\model\Base;

class Config extends Base
{
    private static $configs = [];

    public static function getConfigValue($key)
    {
        if (empty(self::$configs[$key])) {
            self::$configs[$key] = self::where('key', $key)->find()->value ?? null;
        }
        return self::$configs[$key];
    }
}